Skip to content

[docs-infra] Fix emphasized code loading state#4659

Merged
dav-is merged 12 commits intomui:masterfrom
dav-is:docs-infra/fix-highlighted-code
Apr 28, 2026
Merged

[docs-infra] Fix emphasized code loading state#4659
dav-is merged 12 commits intomui:masterfrom
dav-is:docs-infra/fix-highlighted-code

Conversation

@dav-is
Copy link
Copy Markdown
Member

@dav-is dav-is commented Apr 21, 2026

Note

Upstream PR: mui/mui-public#1303

Preview Deploy

Emphasized lines (blue background // @highlight) are not appearing on first render, despite being marked highlightAt: 'init':

Screenshot From 2026-04-21 19-49-38

After:

image

Also, emphasized lines are always shown on first render, even with highlightAt: 'idle' to avoid a large blue flash

Closes: #4653

@dav-is dav-is added type: bug It doesn't behave as expected. scope: docs-infra Involves the docs-infra product (https://www.notion.so/mui-org/b9f676062eb94747b6768209f7751305). labels Apr 21, 2026
@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Apr 21, 2026

commit: e0c3994

@code-infra-dashboard
Copy link
Copy Markdown

code-infra-dashboard Bot commented Apr 21, 2026

Bundle size

Bundle Parsed size Gzip size
@base-ui/react 0B(0.00%) 0B(0.00%)

Details of bundle changes

Performance

Total duration: 1,276.76 ms ▼-324.09 ms(-20.2%) | Renders: 53 (+0) | Paint: 1,986.17 ms ▼-450.70 ms(-18.5%)

Test Duration Renders
Tabs mount (200 instances) 227.24 ms ▼-67.88 ms(-23.0%) 4 (+0)
Select mount (200 instances) 136.39 ms ▼-56.19 ms(-29.2%) 3 (+0)
Tooltip mount (300 contained roots) 58.62 ms ▼-34.70 ms(-37.2%) 2 (+0)
Checkbox mount (500 instances) 75.29 ms ▼-28.51 ms(-27.5%) 1 (+0)
Mixed surface mount (app-like density) 83.48 ms ▼-27.64 ms(-24.9%) 5 (+0)

...and 7 more. View full report

Details of benchmark changes


Check out the code infra dashboard for more information about this PR.

@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 21, 2026

Deploy Preview for base-ui ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit e0c3994
🔍 Latest deploy log https://app.netlify.com/projects/base-ui/deploys/69f0d249e685d400080e2b93
😎 Deploy Preview https://deploy-preview-4659--base-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@dav-is dav-is changed the title [docs-infra] Fix Emphasized Code Loading [docs-infra] Fix Emphasized Code Loading State Apr 22, 2026
@github-actions github-actions Bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Apr 23, 2026
@github-actions github-actions Bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Apr 23, 2026
@dav-is dav-is marked this pull request as ready for review April 24, 2026 13:48
@dav-is dav-is requested a review from aarongarciah April 24, 2026 13:48
Copy link
Copy Markdown
Member

@aarongarciah aarongarciah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if it's meant to be used like this, but nesting word highlighting in nested highlighted lines breaks the line highlighting:

/* @highlight-start */
&[data-starting-style],
&[data-ending-style] {
  /* @highlight-start */
  opacity: 0;
  transform: scale(0.9); /* @highlight-text "transform" */
  /* @highlight-end */
}
/* @highlight-end */
Image

@dav-is
Copy link
Copy Markdown
Member Author

dav-is commented Apr 24, 2026

@aarongarciah that looks like a bug, thanks for mentioning, I'll draft a fix

Edit: PR

@github-actions github-actions Bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Apr 27, 2026
@github-actions github-actions Bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Apr 28, 2026
@dav-is
Copy link
Copy Markdown
Member Author

dav-is commented Apr 28, 2026

@aarongarciah the issue is fixed now

image

@dav-is dav-is requested a review from aarongarciah April 28, 2026 15:39
@dav-is dav-is merged commit 89d9a37 into mui:master Apr 28, 2026
24 checks passed
@dav-is dav-is deleted the docs-infra/fix-highlighted-code branch April 28, 2026 20:32
@oliviertassinari oliviertassinari changed the title [docs-infra] Fix Emphasized Code Loading State [docs-infra] Fix emphasized code loading state Apr 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope: docs-infra Involves the docs-infra product (https://www.notion.so/mui-org/b9f676062eb94747b6768209f7751305). type: bug It doesn't behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants